File upload service
Endpoints
URL ในการเข้าถึงไฟล์ ให้ต่อด้วย path file ที่ได้ไปจากตอน upload, asset ที่ไม่ public ต้องต่อด้วย sig ใน query param เสมอ
The request has succeeded.
curl --request GET \
--url https://dpt-api.finema.dev/files/__FILE_PATH__…The request has succeeded.
Upload file to common storage : is_public = ตั้งค่าเป็น public access (ไม่ต้องใช้ sig ในการเข้าถึง)
binary data, used to describe files
The request has succeeded.
curl --request POST \
--url https://dpt-api.finema.dev/files \
--header 'Authorization: Bearer YOUR_SECRET_TOKEN' \
--header 'Content-Type: multipart/form-data'{
"url": "https://dpt-api.finema.dev/files/xxx/d7d4bcc9-0424-4c4f-a0a0-073ceea5757d.pdf?sig=lfhVvVF3VFvfpLvmfO5VFoi46vfdKipL",
"file_name": "d7d4bcc9-0424-4c4f-a0a0-073ceea5757d.pdf",
"prefix": "xxx",
"path": "files/xxx/d7d4bcc9-0424-4c4f-a0a0-073ceea5757d.pdf",
"size": 15475,
"name": "original_my_file_name.png",
"mime_type": "png",
"sig": "c1397hkljhlih38981hjkhlih3io9o7901hjljk189803il1h97"
}The request has succeeded.